/**
 * 
 */
package com.ambow.service.impl;

import java.util.List;

import com.ambow.Entity.Stock;
import com.ambow.dao.StockDao;
import com.ambow.dao.impl.StockDaoImpl;
import com.ambow.service.StockService;

/**
 * @author Administrator
 *
 */
public class StockServiceImpl implements StockService {
	
	StockDao stockDao=new StockDaoImpl();

	/* (non-Javadoc)
	 * @see com.ambow.service.StockService#Query(java.lang.String, java.lang.String[])
	 */
	@Override
	public List<Stock> Query(String sql, String[] param) {
		// TODO Auto-generated method stub
		
		List<Stock> list= stockDao.StockQuery(sql, param);
		
		return list;
	}

	/* (non-Javadoc)
	 * @see com.ambow.service.StockService#QueryOne(java.lang.String, java.lang.String[])
	 */
	@Override
	public Stock QueryOne(String sql, String[] param) {
		// TODO Auto-generated method stub
		return stockDao.stockQueryOne(sql, param);
	}

	@Override
	public Stock getOne(Class c, int id) {
		// TODO Auto-generated method stub
		return stockDao.getOne(c, id);
	}

	@Override
	public boolean update(Stock stock) {
		// TODO Auto-generated method stub
		return stockDao.update(stock);
	}

	@Override
	public boolean add(Stock stock) {
		// TODO Auto-generated method stub
		return stockDao.add(stock);
	}

	/* (non-Javadoc)
	 * @see com.ambow.service.StockService#queryStock(java.lang.String)
	 */
	@Override
	public Stock queryStock(String hql) {
		// TODO Auto-generated method stub
		return stockDao.queryStock(hql);
	}
	

}
